package com.ruoyi.system.mapper;

import com.ruoyi.common.core.domain.DTO.InsertUserAddressBO;
import com.ruoyi.common.core.domain.DTO.UpdateUserAddressBO;
import com.ruoyi.common.core.domain.entity.UserAddress;
import com.ruoyi.common.core.domain.entity.UserPoints;
import com.ruoyi.common.core.domain.entity.UserPointsLog;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * 参数配置 数据层
 *
 * @author ruoyi
 */
@Mapper
@Repository
public interface UserAddressMapper {
    void insertUserAddress(UserAddress userAddress);
    void updateUserAddress(UserAddress userAddress);
    List<UserAddress> selectByUserId(@Param("userId") Long userId);
    //查询默认地址
    UserAddress selectDefaultByUserId(@Param("userId") Long userId);
    //重置用户的默认地址
    void resetDefaultByUserId(@Param("userId") Long userId);
}
